﻿@model Eyskens.AutoTaggerWeb.Models.EmptyWord

@using (Html.BeginForm()) 
{
    @Html.AntiForgeryToken()
    <p style="margin-top:90px;"></p>
    <div class="form-horizontal">        
        @Html.ValidationSummary(true, "", new { @class = "text-danger" })
        <div class="form-group">
            @Html.LabelFor(model => model.word, htmlAttributes: new { @class = "control-label col-md-2" })
            <div class="col-md-10">
                @Html.EditorFor(model => model.word, new { htmlAttributes = new { @class = "form-control" } })
                @Html.ValidationMessageFor(model => model.word, "", new { @class = "text-danger" })
            </div>
        </div>

        <div class="form-group">
            @Html.LabelFor(model => model.lang, htmlAttributes: new { @class = "control-label col-md-2" })
            <div class="col-md-10">
               @{
                    var items = new SelectList(new[]
                    {
                       new SelectListItem {Text = "eng", Value = "eng"},
                       new SelectListItem {Text = "fra", Value = "fra"},
                    }, "Text", "Value");
                }
                @Html.DropDownListFor(model => model.lang, @items)
                @Html.ValidationMessageFor(model => model.lang, "", new { @class = "text-danger" })
            </div>
        </div>

        <div class="form-group">
            <div class="col-md-offset-2 col-md-10">
                <input type="submit" value="Create" class="btn btn-default" />
            </div>
        </div>
    </div>
}

<div>
    @Html.ActionLink("Back to List", "Index",
                new
                {
                    letter = "A",
                    SPHostUrl = HttpContext.Current.Request.QueryString["SPHostUrl"],
                    SPAppWebUrl = HttpContext.Current.Request.QueryString["SPAppWebUrl"]
                })
</div>
